#include "main.h"
#include "fake-result.h"

int main(int argc, char **argv)
{
  srand(time(NULL));

  try {
    vector<int> tests = getNumberOfTests(argc, argv);

    FinalResult results = testSortGenerateData<int>(tests);

    //FinalResult results = buildFakeResult();
    
    //showFinalResults(results);
    
    plotFinalResults(results,{"rand-asc"},{"heap","quick","merge","stl"},"int-rand-asc.svg");
    plotFinalResults(results,{"rand-desc"},{"heap","quick","merge","stl"},"int-rand-desc.svg");
    plotFinalResults(results,{"asc-asc"},{"heap","quick","merge","stl"},"int-asc-asc.svg");
    plotFinalResults(results,{"desc-desc"},{"heap","quick","merge","stl"},"int-desc-desc.svg");
    plotFinalResults(results,{"asc-desc"},{"heap","quick","merge","stl"},"int-asc-desc.svg");
    plotFinalResults(results,{"desc-asc"},{"heap","quick","merge","stl"},"int-desc-asc.svg");

    return 0;

  } catch (const exception &e) {
    cerr << "Erro! " << e.what() << endl;
    return 1;
  }
}
